package com.crane.oss.school.service;

import java.util.List;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.crane.common.core.dto.MultiResponse;
import com.crane.common.core.dto.Response;
import com.crane.common.core.dto.SingleResponse;
import com.crane.oss.app.bean.request.mqtt.UpdateModeResp;
import com.crane.oss.app.bean.request.mqtt.UpdateMusicModeReq;
import com.crane.oss.school.bean.request.QueryStudentEquipmentReq;
import com.crane.oss.school.bean.request.studentequipment.AddStudentEquipmentReq;
import com.crane.oss.school.bean.request.studentequipment.UpdateStudentEquipmentReq;
import com.crane.oss.school.bean.resp.StudentEquipmentIndexResp;
import com.crane.oss.school.bean.resp.StudentEquipmentResp;

/**
 * 学生器材表
 *
 * @author zhenxing.pi
 * @email ccsu123456@qq.com
 * @date 2023年01月17日 23时03分27秒
 */
public interface StudentEquipmentService {

	/**
	 * 查詢对象
	 *
	 * @param id
	 * @return
	 */
	StudentEquipmentResp queryStudentEquipment(Long id);

	/**
	 * 查询列表
	 *
	 * @param request
	 * @return
	 */
	IPage<StudentEquipmentResp> queryList(QueryStudentEquipmentReq request);

	/**
	 * 保持对象
	 *
	 * @param request
	 * @return
	 */
	int save(AddStudentEquipmentReq request);

	/**
	 * 修改对象
	 *
	 * @param request
	 * @return
	 */
	int update(UpdateStudentEquipmentReq request);

	/**
	 * 删除对象
	 *
	 * @param id
	 * @return
	 */
	int delete(Long id);

	/**
	 * 查询我的跳绳
	 * @param studentId
	 * @return
	 */
	List<StudentEquipmentIndexResp> queryEquipmentForIndex(Long studentId);

	/**
	 * 绑定设备
	 * @param studentId
	 * @param imei
	 * @return
	 */
	Response bindEquiment(Long studentId,String imei);
	/**
	 * 解绑设备
	 * @param studentId
	 * @param imei
	 * @return
	 */
	Response unBindEquiment(Long studentId,String imei);

	/**
	 * 设置模式
	 * @param studentId
	 * @param musicMode
	 * @return
	 */
	MultiResponse<UpdateModeResp> musicModeRope (Long studentId, int musicMode);

	MultiResponse<UpdateModeResp> skipModeRope (Long studentId,int skipmode);

	Integer queryEquipmentMusicMode  (Long studentId);

}
